namespace Digitalmes.Application.Mes.Processes.Operations.Commands;

internal sealed class CreateOperationCommandValidator : AbstractValidator<CreateOperationCommand>
{
    public CreateOperationCommandValidator()
    {
        RuleFor(v => v.Operation.OpCode).MaximumLength(32).NotEmpty();
        RuleFor(v => v.Operation.OpName).MaximumLength(64).NotEmpty();
        RuleFor(v => v.Operation.LineId).GreaterThan(0);
        RuleFor(v => v.Operation.WsIds).NotEmpty();
    }
}
